<template>
  <div>
    <Authc permissions="trade:payment:manager">
      <div>
        <a @click="handleDetail('edit')">编辑</a>
        <a style="margin: 0 4px;" @click="handleDetail('delete')">删除</a>
       <!-- <Tooltip placement="top" content="编辑">
          <Icon class="normal-icon-style" type="ios-create" @click="handleDetail('edit')" />
        </Tooltip>
        <Tooltip placement="top" content="删除">
          <Icon class="normal-icon-style" type="ios-trash" @click="handleDetail('delete')" />
        </Tooltip> -->
      </div>
    </Authc>
  </div>
</template>
<script>
  import {
    Icon,
    Tooltip,
    Message,
    Modal
  } from "view-design";
  import {
    namespace
  } from "../../Module/payChahel.js";
  import Authc from "@/components/Authc";

  export default {
    props: {
      row: Object
    },
    model: {
      event: ["onEdit"]
    },
    components: {
      Icon,
      Tooltip,
      Message,
      Authc
    },
    data: function() {
      return {};
    },
    methods: {
      handleDetail(type) {
        let id = this.$props.row.id || 164649326497446;
        switch (type) {
          case 'edit':
            this.$bus.$emit('actionType', {type: 'edit', id: id });
            break
          case 'delete':
            this.$bus.$emit('actionType', {type: 'delete', id: id });
            break
        }
      }
    }
  };
</script>
<style lang="less">
  .normal-icon-style {
    font-size: 20px !important;
    color: #57a3f3 !important;
  }

  .error-icon-style {
    font-size: 20px !important;
    color: #ff0000 !important;
  }
</style>
